package com.lck.blogmanager.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.lck.blogmanager.entity.FileEntity;
import com.lck.blogmanager.req.FilePageReq;
import com.lck.blogmanager.req.UserPageFileReq;
import com.lck.blogmanager.res.FilePageRes;
import com.lck.blogmanager.res.UserPageFileRes;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

@Component
@Mapper
public interface FileMapper extends BaseMapper<FileEntity> {

    Page<UserPageFileRes> userPageFile(@Param("req") UserPageFileReq req,
                                       Page page);

    Page<FilePageRes> pageFile(@Param("req") FilePageReq req,
                               Page page);
}
